<?php

$num1 = $_POST['num1'];
$num2 = $_POST['num1'];
$fuhao = $_POST['fuhao'];

if($fuhao=="+"){
	echo $num1+$num2;
}elseif($fuhao=="-"){
	echo $num1-$num2;
}elseif($fuhao=="*"){
	echo $num1*$num2;
}elseif($fuhao=="/"){
	echo $num1/$num2;
}else{
	echo "数据有问题";
}

switch ($fuhao) {
	case '+':
		echo $num1+$num2;
		break;
	case '-':
		echo $num1-$num2;
		break;
	case '*':
		echo $num1*$num2;
		break;
	case '/':
		echo $num1/$num2;
		break;
	default:
		echo "数据有问题";
		break;
}